#pragma once
/*
@author: TriLVH
@description: basic data of army obj, extends from abstractdata with improve target information (player bouding)
*/

#include "AbstractData.h"
#include "BulletContainer.h"

class ArmyData : public AbstractData {
public:
	ACTIONS _actions;
	/* Reference arget to the player bouding*/
	Rect* targetRect;

	/* Range of effect of army */
	Rect* rangeOfEffect;

	/* Container of bullet */
	BulletContainer * bulletContainer;

	/* Check if army is active in range */
	bool isActived;
	bool isHalf;

	/* Constructor to init data(this base on ArmyFactory) */
	ArmyData() {

	}

	/*  */
	ArmyData(int id, int type, double x, double y, Rect* rangeOfEffect);

	/* Init sprite handler from Singleton of device */
	virtual void initSpriteHandler(LPD3DXSPRITE spriteHandler);

	virtual void initSpriteHandler();

	virtual bool _checkInRange();

	virtual bool checkTargetAhead();
};